﻿Imports System

Namespace System.Workflow.Runtime
    Friend Class LockFactory
        ' Methods
        Friend Shared Function CreateWorkflowExecutorLock(ByVal id As Guid) As InstanceLock
            Return New InstanceLock(id, ("Workflow Executor Lock: " & id.ToString), 50, LockPriorityOperator.GreaterThanOrReentrant)
        End Function

        Friend Shared Function CreateWorkflowMessageDeliveryLock(ByVal id As Guid) As InstanceLock
            Return New InstanceLock(id, ("Workflow Message Delivery Lock: " & id.ToString), &H23, LockPriorityOperator.GreaterThanOrReentrant)
        End Function

        Friend Shared Function CreateWorkflowSchedulerLock(ByVal id As Guid) As InstanceLock
            Return New InstanceLock(id, ("Workflow Scheduler Lock: " & id.ToString), 40, LockPriorityOperator.GreaterThan)
        End Function

    End Class
End Namespace

